using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace MyXnaGame
{
    public class HudTextComponent : HudComponent
    {
        //SpriteFont hudFont;
        //Vector2 position;

        private string hudText = "Some Text";

        public HudTextComponent(string hudText, SpriteFont hudFont)
        {
            //this.position = new Vector2(20, 20);
            this.hudText = hudText;
            this.hudFont = hudFont;
        }
        public HudTextComponent(string hudText, PresetPosition presetPosition)
        {
            base.SetPosition(presetPosition);
            this.hudText = hudText;
        }
        public HudTextComponent(string hudText, SpriteFont hudFont, PresetPosition presetPosition)
        {
            base.SetPosition(presetPosition);
            this.hudText = hudText;
            this.hudFont = hudFont;
        }
        public HudTextComponent(string hudText, SpriteFont hudFont, Vector2 position)
        {
            this.position = position;
            this.hudText = hudText;
            this.hudFont = hudFont;
        }

        public override void Draw(SpriteBatch spriteBatch)
        {
            spriteBatch.DrawString(hudFont, hudText, position, Color.Green);
        }
    }
}
